-- XSD schema extracted from ITU-T H.627 (08/2020)
<?xml version="1.0" encoding="utf-8"?>
<schema xmlns="http://www.w3.org/2001/XMLSchema">
<simpleType name="deviceIDType">
<restriction base="ID">
<!--when representing the administrative zone ID, the value is 4-bit country or area code + zone code (the 8-bit zone code can be divided according to the specific situation, for example, the 8-bit zone code is divided by every two digits, the administrative zone value is 6, 8, 10, 12 bits); when representing device ID/ VSS ID, the value is 24 bits.-->
<pattern value="(\d{6}|\d{8}|\d{10}|\d{12}|\d{24})"/>
</restriction>
</simpleType>
<simpleType name="statusType">
<restriction base="string">
<enumeration value="ON"/>
<enumeration value="OFF"/>
</restriction>
</simpleType>
<simpleType name="resultType">
<restriction base="string">
<enumeration value="OK"/>
<enumeration value="ERROR"/>
</restriction>
</simpleType>
<simpleType name="PTZType">
<restriction base="string">
<length value="8"/>
</restriction>
</simpleType>
<simpleType name="recordType">
<restriction base="string">
<enumeration value="Record"/>
<enumeration value="StopRecord"/>
</restriction>
</simpleType>
<simpleType name="guardType">
<restriction base="string">
<enumeration value="SetGuard"/>
<enumeration value="ResetGuard"/>
</restriction>
</simpleType>
<complexType name="itemType">
<sequence>
<!-- Device/administrative zone/VSS code (required) -->
<element name="DeviceID" type="deviceIDType"/>
<!-- Device/administrative zone/VSS name (required) -->
<element name="Name" type="string"/>
<!-- if it is a device, device manufacturer (required) -->
<element name=" Manufacturer" type="string"/>
<!-- if it is a device, device model (required) -->
<element name=" Model" type="string"/>
<!-- if it is a device, device owner (required) -->
<element name=" Owner" type="string"/>
<!-- if it is a device, ZoneCode (required) -->
<element name="ZoneCode" type="string"/>
<!-- Block (optional) -->
<element name="Block" type="string"/>
<!-- if it is a device, installation address (required) -->
<element name="Address" type="string"/>
<!-- if it is a device, whether there is a sub device (required), 1-yes, 0-no -->
<element name="Parental" type="integer" minInclusive="0"/>
<!-- if it is a device, the parent node ID (required): if there is no parent device, it is the system ID of the device; if there is a parent device, it is the parent device ID; if it is a VSS, the parent node ID (it is required if there is a parent node VSS): it is the parent node VSS ID;
if it is an administrative zone, no parent node ID; can be multi-value, separated by "/" -->
<element name="ParentID" type="string"/>
<!-- Device /VSS IPV4 address (optional) -->
<element name="IPAddress" type="string"/>
<!-- Device /VSS port (optional) -->
<element name="Port" type="integer"/>
<!-- Device password (optional) -->
<element name="Password" type="string"/>
<!-- Device status (optional) -->
<element name="Status" type=" statusType"/>
<!-- if it is a device, longitude (optional) WGS-84 coordinate system-->
<element name="Longitude" type="double" minOccurs="0"/>
<!-- if it is a device, latitude (optional) WGS-84 coordinate system-->
<element name="Latitude" type="double" minOccurs="0"/>
<Info>
<!-- Camera type extension, markup camera type: 1-ballhead camera; 2-hemisphere; 3-fixed bolt; 4-remote control bolt; 5-remote control hemisphere; 6-multicamera; 7-integrated gun ball linkage camera, can be multi-value, separated by "/". It is optional when the directory entry is camera. -->
<element name="PTZType" type="string" minOccurs="0"/>
<!-- Camera photoelectric imaging type. 1-visible light imaging; 2-thermal imaging; 9-other. It is optional when the directory entry is camera. -->
<element name="PhotoelectricImagingType" type="string" minOccurs="0"/>
<!-- Camera position type extension. 1-Inter-provincial checkpoint, 2-party and government organizations, 3-station and dock, 4-central plaza, 5-stadium, 6-business center, 7-religious venue, 8-campus surrounding, 9-security complex area, 10-arterial traffic. It is optional when the directory entry is camera. -->
<element name="PositionType" type="string" minOccurs="0"/>
<!-- Outdoor and indoor camera mounting position type. 1-outdoor, 2-indoor. It is optional when the directory entry is camera, and defaults as 1. -->
<element name="RoomType" type="integer" default="1"/>
<!-- Camera fill light type. 1-no fill light, 2-infrared fill light, 3-white fill light, 4-laser fill light, 9-othe. It is optional when the directory entry is camera, and defaults as 1. -->
<element name="SupplyLightType" type="integer" default="1"/>
<!-- Camera surveillance direction (optical axis direction) type. 1-East (west to east), 2-west (east to west), 3-south (north to south), 4-north (south to north), 5-southeast (northwest to southeast), 6-northeast (southwest to northeast), 7-southwest (northeast to southwest), 8-northwest (southeast to northwest), 9-other. It is optional when the directory entry is the fixed camera or set to be the guard camera. -->
<element name="DirectionType" type="integer" minOccurs="0"/>
<!-- Resolution supported by the camera, there are multiple resolution values separated with "/". For the resolution values, refer to the SDP f field provisions of clause 7.7. It is optional when the directory entry is camera. -->
<element name="Resolution" type="string" minOccurs="0"/>
<!-- List of stream numbers supported by the camera, it is used to specify the stream numbers during live video on demand, with multiple values separated by "/". For example, "0/1/2" indicates support for the primary stream, the secondary stream and the second auxiliary stream.-->
<element name=" StreamNameList " type="string" minOccurs="0"/>
<!-- Download speed range (optional), the optional parameters are separated with "/"; if the device supports 1, 2 and 4 times the speed, it shall be written as "1/2/4"-->
<element name="DownloadSpeed" type="string" minOccurs="0"/>
<!-- Mobile acquisition device type (it is required if the device type code is 138); 1-camera on mobile robot; 2-law enforcement recorder; 3-mobile soldier equipment; 4-vehicle video recording equipment; 5-unmanned aerial vehicle camera; 9-other -->
<element name="MobileDevieType" type="integer" minOccurs="0"/>
<!-- Camera horizontal field of view angle (optional), the value range is greater than 0 degrees and less than or equal to 360 degrees -->
<element name="HorizontalFieldAngle" type="double" minOccurs="0"/>
<!-- Camera vertical field of view angle (optional), the value range is greater than 0 degrees and less than or equal to 360 degrees -->
<element name="VerticalFieldAngle" type="double" minOccurs="0"/>
<!-- Camera visible distance (optional), unit: meter -->
<element name=" MaxViewDistance " type="double" minOccurs="0"/>
<!-- The common name of the point (optional), if there are landmark buildings, places or monitoring points near the monitoring point, it can be filled in the landmark construction name and location.-->
<element name="PointCommonName" type="string" minOccurs="0"/>
<!-- Device MAC address (optional), in the format of "XX-XX-XX-XX-XX-XX", where "XX" represents two hexadecimal numbers, separated by "-"-->
<element name="MAC" type="string" minOccurs="0"/>
<!-- Camera function type, 01-facebayonet; 02-person bayonet; 03-motor vehicle bayonet; 04-non-motor vehicle bayonet; 05-item bayonet; 99-other, multiple selection, parameters are separated by "/". Optional when it is a camera -->
<element name="FunctionType" type="string" minOccurs="0"/>
<!-- Camera video encoding format (optional), the value is specified in the SDP f field in clause 7.7 -->
<element name="EncodeType" type="string" minOccurs="0"/>
<!-- Camera installation time (optional) -->
<element name="InstallTime" type="dateTime" minOccurs="0"/>
<!-- Name of camera management unit (optional) -->
<element name="ManagementUnit" type="string" minOccurs="0"/>
<!-- Contact information (phone number) of the contact person of the management unit to which the camera belongs (optional)-->
<element name="ContactInfo" type="string" minOccurs="0"/>
<!-- Video save days (optional) -->
<element name="RecordSaveDays" type="integer" minOccurs="0"/>
</Info>
</sequence>
</complexType>
<complexType name="itemFileType">
<sequence>
<!-- Device ID (required) -->
<element name="DeviceID" type="deviceIDType"/>
<!-- Device name (required) -->
<element name="Name" type="string"/>
<!-- File path name (optional)-->
<element name=" FilePath" type="string" minOccurs="0"/>
<!-- Recording address (optional)-->
<element name="Address" type="string" minOccurs="0"/>
<!-- Recording start time (optional)-->
<element name="StartTime" type="dateTime" minOccurs="0"/>
<!-- Recording end time (optional)-->
<element name="EndTime" type="dateTime" minOccurs="0"/>
<!-- Video type (optional) time or alarm or manual-->
<element name="Type" type="string" minOccurs="0"/>
<!-- Recorder ID (optional) -->
<element name="RecorderID" type="string" minOccurs="0"/>
<!-- Video file size, unit: Byte (optional) -->
<element name="FileSize" type="string" minOccurs="0"/>
<!-- PU/VSS ID for storing video files (required for fuzzy query) -->
<element name="RecordLocation" type="deviceIDType"/>
</sequence>
</complexType>
<complexType name="PTZPreciseCtrlType">
<!-- Set the horizontalangle of the cradle head (optional), 0~360.00 degrees.
0 degree: absolute 0 degree is based on the horizontal optocoupler of the ballhead camera, relative 0 degree is subject to the actual setting.
The user first sets the relative origin coordinates, determines the relative 0 degree position, and sets the cradle head angle with respect to the relative 0 degree as the starting point.
Direction: the ballhead camera is installed upright, viewed from the top down, clockwise direction increases, counter clockwise direction decreases;
If the received command parameter exceeds the actual rotation angle limit of the device, it will move to the actual maximum angle.-->
<element name="Pan" type="double" minOccurs="0"/>
<!-- Set the vertical angle of the cradle head (optional), The general value is -30.00~90.00 degrees;
0 degree: when the ballhead camera is installed vertically, the horizontal position of the lens is 0 degree.
Direction: when the ballhead camera is installed vertically, if the lens turn up, the degree will decrease; if the lens turn down, the degree will increase.
If the received command parameter exceeds the actual reach of the device, then move to the actual maximum limit angle position.
For example, if the value of receiving command value is -28.00 and the maximum limit angle is -20.00, it is enough to move to -20.00.-->
<element name="Tilt" type="double" minOccurs="0"/>
<!-- Set the zoom factor (optional), the value is generally greater than 1.00.
If the receiving command parameter is within the optical zoom maximum value, it will move to the corresponding optical zoom factor.
When the optical zoom maximum value is exceeded, the corresponding digital zoom will be activated. The device shall check the validity of the parameter value.
For example, if the device optical zoom maximum value is 36.00 and the receiving command parameter is 72.00, the action will be 36.00x optical zoom and 36.00x digital zoom (if the device digital zoom maximum value is less than 36.00, the actual maximum value shall be executed) .-->
<element name="Zoom" type="double" minOccurs="0"/>
</complexType>
<element name="OSDConfigType" minOccurs="0">
<complexType>
<sequence>
<!-- Configure window length pixel values (required)-->
<element name="Length" type="integer"/>
<!-- Configure window width pixel values (required)-->
<element name="Width" type="integer"/>
<!-- Time X pixel coordinates (required), the pixel in the upper left corner of the playback window is the origin, and the horizontal right is positive.-->
<element name="TimeX" type="integer"/>
<!-- Time Y pixel coordinates (required), the pixel in the upper left corner of the playback window is the origin, and the vertical down is positive-->
<element name="TimeY" type="integer"/>
<!-- Display time switch (optional), 0-off; 1-open (default value)-->
<element name="TimeEnable" type="integer" default="1"/>
<!-- Time display type (optional):
0- Year-Month-Day Hour:Minute:Second
1- Year Month Day Hour:Minute:Second
2- Day/Month/Year Hour:Minute:Second
3- Month /Day/Year Hour:Minute:Second -->
<element name="TimeType" type="integer" minOccurs="0"/>
<!-- Display text switch (optional), 0-off; 1-open (default value)-->
<element name="TextEnable" type="integer" default="1"/>
<!-- Text list (optional)-->
<element name="Item" minOccurs="0" maxOccurs="8"/>
<complexType>
<sequence>
<!-- Text content, length range 0 ~ 32 (required)-->
<element name="Text" type="string"/>
<!-- Text X coordinate (required)-->
<element name="X" type="integer"/>
<!-- Text Y coordinate (required)-->
<element name="Y" type="integer"/>
</sequence>
</complexType>
</sequence>
</complexType>
</element>
<complexType name="videoParamAttributeType">
<sequence>
<!-- Video stream name (required), such as the first video stream Stream1, the second video stream Stream2 -->
<element name="StreamName" type="string"/>
<!-- Video stream number (required), used to specify the stream number in real-time video and audio on demand. 0-main stream; 1-substream; 2-second auxiliary stream, and soon-->
<element name="StreamNumber" type="integer"/>
<!-- The current configuration value of the video encoding format (required). The value is specified in the SDP f field in clause 7.7.-->
<element name="VideoFormat" type="string"/>
<!-- Resolution current configuration value (required). The value is specified in the SDP f field in clause 7.7.-->
<element name="Resolution" type="string"/>
<!-- Frame rate current configuration value (required). The value is specified in the SDP f field in clause 7.7.-->
<element name="FrameRate" type="string"/>
<!-- Rate type configuration value (required).The value is specified in the SDP f field in clause 7.7.-->
<element name="BitRateType" type="string"/>
<!-- Video bitrate configuration value (required for fixed bitrate),The value is specified in the SDP f field in clause 7.7.-->
<element name="VideoBitRate" type="string" minOccurs="0"/>
</sequence>
</complexType>
<complexType name="itemMobilePositionType">
<sequence>
<!-- Target device code (required) -->
<element name="DeviceID" type="deviceIDType"/>
<!-- Location collection time (required) -->
<element name="CaptureTime" type="dateTime"/>
<!-- Longitude (required), WGS-84 coordinate system -->
<element name="Longitude" type="double"/>
<!-- Latitude (required), WGS-84 coordinate system -->
<element name="Latitude" type="double"/>
<!-- Speed, unit: km/h (optional) -->
<element name="Speed" type="double" minOccurs="0"/>
<!-- Direction angle (optional), the value is the clockwise angle between the current camera direction and the north, the value range is greater than or equal to 0 less than 360, unit: degree -->
<element name="Direction" type="double" minOccurs="0"/>
<!-- Altitude, unit: meter (optional) -->
<element name="Altitude" type="double" minOccurs="0"/>
<!-- Ground height, unit: meter (optional) -->
<element name="Height" type="double" minOccurs="0"/>
</sequence>
</complexType>
</schema>